package com.magenta.maxoptra.gis;

import java.util.List;

/**
 * @author Sergey Grachev
 */
public interface RoutingServiceMBean {
    GeoProviderStatus updateCache(GeoProviderSettings settings, RoutingCoordinate from, RoutingCoordinate to, int delayBeforeRequests);

    /**
     * Bath updating for routes from origin to destination
     *
     * @param settings            geo provider settings
     * @param origin              starting point of the routes
     * @param destinations        list of final destinations
     * @param delayBeforeRequests time that you need to wait before using the provider
     * @return current status of provider
     */
    @Deprecated
    GeoProviderStatus updateCache(GeoProviderSettings settings, GeographicCoordinates origin,
                                  List<? extends GeographicCoordinates> destinations, int delayBeforeRequests);

    void updateCache(GeoProviderSettings settings, RoutingCoordinate from, List<RoutingCoordinate> points);

    void updateCache(GeoProviderSettings settings, List<RoutingCoordinate> from, List<RoutingCoordinate> to);
}
